package login

import (
	"3-6zk/common/proto/user"
	"3-6zk/service/server"
	"context"
)

type UserServer struct {
	user.UnimplementedUserServer
}

func (s UserServer) Login(ctx context.Context, req *user.LoginReq) (*user.LoginResp, error) {
	login, err := server.Login(req)
	if err != nil {
		return nil, err
	}
	return login, nil
}
func (s UserServer) SendSms(ctx context.Context, req *user.SendSmsReq) (*user.SendSmsResp, error) {
	sms, err := server.SendSms(req)
	if err != nil {
		return nil, err
	}
	return sms, nil
}
